﻿@inject IStringLocalizer<InputNumbersValidateForm> Localizer

<div>
    <Divider Text="@Localizer["InputNumbersValidateFormDivider1"]" Alignment="Alignment.Left" style="margin: 2rem 0;"></Divider>
    <ValidateForm Model="@Model">
        <BootstrapInputNumber @bind-Value="@Model.Count" ShowLabel="true" />
    </ValidateForm>
    <Divider Text="@Localizer["InputNumbersValidateFormDivider2"]" Alignment="Alignment.Left" style="margin: 2rem 0;" />
    <BootstrapInputNumber @bind-Value="@Model.Count" ShowLabel="false" />
    <Divider Text="@Localizer["InputNumbersValidateFormDivider3"]" Alignment="Alignment.Left" style="margin: 2rem 0;"></Divider>
    <BootstrapInputNumber @bind-Value="@Model.Count" ShowLabel="true" DisplayText="@Localizer["InputNumbersValidateFormInputText"]" />
</div>

<style>
    .demo-inputnumber {
        width: 160px;
    }

        .demo-inputnumber > .form-control {
            width: inherit;
        }
</style>

@code {

    /// <summary>
    ///
    /// </summary>
    public int BindValue { get; set; } = 5;

    /// <summary>
    ///
    /// </summary>
    public sbyte BindSByteValue { get; set; } = 10;

    /// <summary>
    ///
    /// </summary>
    public byte BindByteValue { get; set; } = 10;

    /// <summary>
    ///
    /// </summary>
    public long BindLongValue { get; set; } = 10;

    /// <summary>
    ///
    /// </summary>
    public short BindShortValue { get; set; } = 10;

    /// <summary>
    ///
    /// </summary>
    public double BindDoubleValue { get; set; } = 10;

    /// <summary>
    ///
    /// </summary>
    public float BindFloatValue { get; set; } = 10;

    /// <summary>
    ///
    /// </summary>
    public decimal BindDecimalValue { get; set; } = 10;

    private Foo Model { get; set; } = new Foo() { Count = 10 };
}
